package by.blog.service;


import by.blog.dao.beans.User;
import by.blog.dao.dao.DaoUser;

/**
 * Бондарчик Антон  15.11.2014.
 */
public class UserService implements ServiceInterface<User, String> {
    private DaoUser daoUser;


    public UserService() {
        daoUser = new DaoUser();
    }

    public boolean createUnit(User user) {
        boolean state = daoUser.createUnit(user);
        return state;
    }

    public User readUnit(String USER_NAME) {
        return daoUser.readUnit(USER_NAME);
    }

    public boolean updateUnit(User user) {
        boolean state = daoUser.updateUnit(user);
        return state;
    }

    public boolean deleteUnit(String USER_NAME) {
        boolean state = daoUser.deleteUnit(USER_NAME);
        return state;
    }






}
